/*
 * @(#)Author.java 0.0.1-SNAPSHOT
 * Copyright Group B
 */

package grupb.upf.XMLObjects.impl;

import java.io.Serializable;

/**
 * <p>This class implements Author. It is used to manage the Author objects.</p>
 *
 * @version    0.0.1-SNAPSHOT
 * @author     Group B
 */
public final class Author implements grupb.upf.XMLObjects.Author, Serializable {

    /**
     * The serialVersionUID is created to be able to serialize this class, it's
     * necessary because it will be sent.
     */
    private static final long serialVersionUID = 1L;
    /**
     * This is the name of the author.
     */
    private String aName;
    /**
     * This is the surname of the author.
     */
    private String aSurname;
    /**
     * This is the account of the author.
     */
    private String aAccount;

    /**
     * Method to set the name of the author.
     * @param name the name of the author
     */
    @Override
    public void setName(final String name) {
        this.aName = name;
    }

    /**
     * Method to get the name of the author.
     * @return the name of the author
     */
    @Override
    public String getName() {
        return this.aName;
    }

    /**
     * Method to set the surname of the author.
     * @param surname the surname of the author
     */
    @Override
    public void setSurname(final String surname) {
        this.aSurname = surname;
    }

    /**
     * Method to get the surname of the author.
     * @return the surname of the author
     */
    @Override
    public String getSurname() {
        return this.aSurname;
    }

    /**
     * Method to set the account of the author (i.e. author@gmail.com).
     * @param account the account of the author
     */
    @Override
    public void setAccount(final String account) {
        this.aAccount = account;
    }

    /**
     * Method to get the account of the author.
     * @return the account of the author
     */
    @Override
    public String getAccount() {
        return this.aAccount;
    }

    /**
     * Method to clear all the parameters of the author.
     */
    @Override
    public void clear() {
        this.aName = "";
        this.aSurname = "";
        this.aAccount = "";
    }

}
